<?php

// $Id$

require_once(TANGRA_MAIN_DIR.'form/fields/checkbox/form_field_checkbox_view.class.php');
require_once(TANGRA_MAIN_DIR.'form/fields/integer/form_field_integer_view.class.php');
require_once(TANGRA_MAIN_DIR.'form/guardable_form_view.class.php');


class Settings_Cache_Form_View extends Guardable_Form_View {
	function __construct(Form &$form) {
		parent::__construct($form);

		$f_switch = $form->get_field('switch');
		$f_switch_view = new Form_Field_Checkbox_View($form->get_name().'_'.$f_switch->get_name(), $f_switch);
		$this->add_field_view('switch', $f_switch_view);

		$f_expiry = $form->get_field('expiry');
		$f_expiry_view = new Form_Field_integer_View($form->get_name().'_'.$f_expiry->get_name(), $f_expiry);
		$this->add_field_view('expiry', $f_expiry_view);

		$f_locked = $form->get_field('locked');
		$f_locked_view = new Form_Field_Checkbox_View($form->get_name().'_'.$f_locked->get_name(), $f_locked);
		$this->add_field_view('locked', $f_locked_view);
	}
}
